"use strict"
import * as net from "net";


let sock = net.connect(9550, "127.0.0.1");
sock.on("connect", ()=>{
    console.log("sock connected");
    
    sock.write(new Buffer([0x80,0x00,0x00,0x00,0x00,0x00]));
    console.log("sock write end 1");
    sock.write(new Buffer([0x80,0x02,0x00,0x00,0x00,0x00]));
    console.log("sock write end 2");
});

sock.on("data", (buffer:Buffer)=>{
    console.log(`sock receive data: ${buffer.toString("hex")}`);

});

















